package blog.spring.db.service;

import blog.core.exception.FormParamErrorException;
import blog.spring.db.entity.User;

public interface IUserService extends IBaseService<User> {

	/**
	 * 登录
	 * @param username 用户名
	 * @param password 密码
	 * @return 登录成功，返回用户对象，失败，返回指定异常
	 */
	public User login(String username,String password) throws FormParamErrorException;

	/**
	 * 添加系统用户
	 * @param user 包含系统用户的User对象
	 * @throws FormParamErrorException
	 */
	void addSysUser(User user) throws FormParamErrorException;
}
